<template>
  <div class="bigbox">
     <div class="mian_contain">
          <div class="postdetail"  v-for="(item, i) in contain">
            <Postdetail :themeMessage ="item.theme_post" :userMessage ="item.person" />
          </div>
       </div>
  </div>
</template>

<script>
import Postdetail from '../../components/post_detail/post_detail.vue';
import {getAllArticle} from "@/api";
import {showThemeAllByFine} from "@/api";
export default {
  components: {
    Postdetail,
  },
  data () {
    return {
      contain:[],
      user:{},
      is_Jlist:0
    }
  },
  created () {
    this.is_Jlist  = this.$route.params.id
    this.user = JSON.parse(window.localStorage.getItem('user' ))
    console.log(this.user);
    let that = this
    if(this.is_Jlist ==undefined){
      getAllArticle()
      .then(res => {
        that.contain = res.data.data
      })
      .catch(() => {});
    }else{
     showThemeAllByFine()
      .then(res => {
        that.contain = res.data.data
      })
      .catch(() => {});
    }
    
  },
  methods: {
      
  }
}
</script>

<style lang="less" scoped>

</style>